Pseudo wire emulation edge to edge (Pseudo Wire Emulation Edge to Edge, PWE3) refers to an edge-to-edge layer 2 service bearing technology, which simulates in a packet switched network (Packet Switched Network, PSN) as realistically as possible basic behaviors and features of services such as an asynchronous transfer mode (Asynchronous Transfer Mode, ATM), frame relay, Ethernet, a low speed time division multiplexing (Time Division Multiplexing, TDM) circuit, a synchronous optical network (Synchronous Optical Network, SONET) and a synchronous digital hierarchy (Synchronous Digital Hierarchy, SDH), and is a point-to-point layer 2 virtual private network (Layer 2 virtual private network, L2VPN).
ATM PWE3 is a technology for bearing an ATM cell in a PWE3 virtual circuit, in which conventional ATM networks are connected by using a PSN network, and emulation of an ATM service is provided in the PSN network. When a conventional ATM network service traverses the PSN network, the original service is emulated to the largest extent, so that an end customer does not feel a difference and investments of the customer user and a provider are protected during network integration and construction.
Referring to FIG. 1 and FIG. 2, the RFC4717 standard formulated by the Internet Engineering Task Force (Internet Engineering Task Force, IETF) defines a reference model of the ATM PWE3. In the ATM PWE3, various layer 2 services of an end of a customer edge (Customer Edge, CE) device, for example, various layer 2 data packets are transparently transferred through a PSN tunnel (Tunner) connecting two provider edge (Provider Edge, PE) devices, for example, a multiprotocol label switching tunnels (Multiprotocol Label Switching Tunner, MPLS Tunner) connecting PE1 and PE2. Between a CE and a PE is an ATM interface (Service) or an x digital subscriber line (x Digital Subscribe Line, xDSL) interface of an ATM mode, where a data encapsulation form is an ATM cell. A tunnel may have a plurality of pseudo wires (Pseudo Wire, PW) used for bearing and transferring a PW packet in which an ATM cell is encapsulated.
The ATM PWE3 has a plurality of encapsulation manners, including: a one to one (one to one) encapsulation manner, an N to one (N to one) encapsulation manner, and the like. According to different ATM connection types borne in a PW packet, the one to one encapsulation manner further includes: a one to one virtual circuit connection (Virtual Circuit Connection, VCC) encapsulation manner and a one to one virtual path connection (Virtual Path Connection, VPC) encapsulation manner; and the N to one encapsulation manner further includes: an N to one virtual circuit connection (Virtual Circuit Connection, VCC) encapsulation manner and an N to one virtual path connection (Virtual Path Connection, VPC) encapsulation manner.
The RFC4717 standard formulated by the IETF defines an encapsulation method of the ATM PWE3. Referring to FIG. 3 and FIG. 4, N to one ATM PWE3 encapsulation and one to one ATM PWE3 encapsulation each include four domains, which successively are: a PSN transport header, a PW header, an ATM control word, and an ATM service payload. When only one ATM cell is encapsulated into a PW packet, encapsulation efficiency is low, and a bandwidth utilization rate is low. Therefore, RFC4717 defines a method for encapsulating a plurality of ATM cells into a PW packet, which is referred to as cell concatenation.
Referring to FIG. 5 and FIG. 6, when the cell concatenation is not used, one PW packet has only one ATM cell. A cell loss priority (Cell Loss Priority, CLP) bit in an ATM cell header may be mapped to a quality of service (Quality of Service, QoS) label of a PSN transport header or a PW header, so as to provide QoS consistent with a CLP of the encapsulated ATM cell during transport in the PSN. When the CLP bit is 1, it represents that the ATM cell may be discarded, and at this time, the QoS is labeled as a low priority. When the CLP bit is 0, it represents that the ATM cell cannot be discarded, and at this time, the QoS is labeled as a high priority.
When cell concatenation encapsulation is adopted, as shown in FIG. 7 and FIG. 8, one PW packet may contain a plurality of ATM cells. Because different ATM cells have different CLP bits and different service types, priorities required to be mapped to QoS labels are also different. For this problem, the RFC4717 suggests that the highest among priorities which is of all the ATM cells in one PW packet and are required to be mapped to QoS labels be mapped to a QoS label of a PSN transport header or a PW header. This causes that the QoS grade of another ATM cell of a low priority in the PW packet is raised during PSN transport, so that the encapsulated ATM cells do not completely emulate an original service during the transport in the PSN.